/*
 * @Author: weikang
 * @Description:
 * @Date: 2023-12-22 10:36:12
 * @LastEditTime: 2024-05-05 13:50:19
 * @FilePath: \env-manager-pc\src\router\modules\statistics.ts
 */
import type { RouteRecordRaw } from 'vue-router'

function Layout() {
  return import('@/layouts/index.vue')
}

const routes: RouteRecordRaw = {
  path: '/statistics',
  component: Layout,
  redirect: '/statistics/data-full',
  name: 'statistics',
  meta: {
    title: '统计分析',
    icon: 'ep:pie-chart',
  },
  children: [
    {
      path: 'data-full',
      name: 'statistics-data-full',
      meta: {
        title: '数据完整率分析',
        auth: '/statistics/data-full',
      },
      children: [{
        component: () => import('@/views/statistics/data_full/index.vue'),
        path: '',
        name: 'statistics-data-full-list',
        meta: {
          title: '数据完整率分析',
          sidebar: false,
          breadcrumb: false,
          activeMenu: '/statistics/data-full',
        },
      }, {
        component: () => import('@/views/statistics/data_full/detail.vue'),
        path: ':id',
        name: 'statistics-data-full-detail',
        meta: {
          title: '企业数据完整率详情',
          sidebar: false,
          breadcrumb: false,
          activeMenu: '/statistics/data-full',
          auth: '/statistics/data-full/:id',
        },
      }],
    },
    {
      path: 'online',
      name: 'statistics-online',
      component: () => import('@/views/statistics/online/index.vue'),
      meta: {
        title: '在线状态分析',
        auth: '/statistics/online',
      },
    },
    {
      path: 'no-document',
      name: 'statistics-no-document',
      component: () => import('@/views/statistics/no_document/index.vue'),
      meta: {
        title: '无档案设备分析',
        auth: '/statistics/no-document',
      },
    },
    // {
    //   path: 'data-err',
    //   name: 'statistics-data-err',
    //   component: () => import('@/views/statistics/data_err/index.vue'),
    //   meta: {
    //     title: '数据异常分析',
    //     auth: '/statistics/data-err',
    //   },
    // },
  ],
}

export default routes
